<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-spring3-3.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:th="http://www.thymeleaf.org">
    <head th:include="staff/template :: header" />
  <body class="main-body">
        <div class="container main-container">
            <div th:substituteby="staff/template :: nav" />               
            <form id="form-horizontal" class="form-horizontal bs-docs-example" method="post" th:action="${catalog}?@{/staff/management/catalog/update_done} : @{/staff/management/catalog/save}">
                <div class="form-group">
                    <label class="col-md-4 control-label" for="catalogName">Tên loại bài viết</label>  
                    <div class="col-md-5">
                        <input th:value="${catalog} ? ${catalog.name}: ${' '}" id="catalogName" name="catalogName" type="text" placeholder="" class="form-control input-md validate[required]" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-md-4 control-label" for="catalogInfo">Thông tin loại bài viết</label>
                    <div class="col-md-5">
                        <input th:value="${catalog} ? ${catalog.info} : ${' '}" type="text" id="catalogInfo" name="catalogInfo" class="form-control input-md validate[required]" placeholder="Miêu tả sơ bộ"/>
                    </div>
                </div>
                <div class="form-group">
                    <div class="col-md-4"/>
                    <div class="col-md-5">
                        <button type="submit" class="btn btn-primary" id="save">Thêm bài viết</button>
                        <a th:href="@{/staff/management/catalog/index}" class="btn btn-info" id="cancel">Thoát</a>
                    </div>
                </div>

            </form>
            <div th:include="staff/template :: footer"></div>
        </div>	       
        <script th:inline="javascript">
            /*<![CDATA[*/
            jQuery(document).ready(function() {
                jQuery("#form-horizontal").validationEngine();
                COMMON.activeMenu("nav_website");
            });
            /*]]>*/
        </script>    
    </body>
</html>